Apache install instructions:
* This is for people with BONE only.  If you don't have BONE you can stop here because this isn't for you.  :-P

Files needed:
Apache with PHP module how-to.txt  Duh, you're reading it :P
apache-n-php_README.first.tar.gz  Not really needed if you follow these instructions but it contains some useful info.
apache_1.3.20.tar.gz
autoconf-2.13.tar.gz
automake-1.4.tar.gz
libtool-1.4.1-beos-1.tar.gz
m4-1.4.tar.gz
openssh-beos.tgz
openssh_ssl.zip
perl561.pkg
php-4.0.6.tar.gz
postgresql-7.1.3.tar.gz
zlib-1.1.3.tar.gz

Unzip sources to /boot/home/files/code/ to retain settings used in these steps.  If you don't like the locations I use you can change them but it may mess you up if you aren't careful.

Install Perl, it's needed for a few things later.

automake:
first do: ./configure --prefix=/boot/home/config
then do: make
then do: make install

m4 uses the same steps as automake

autoconf with those same three steps

Libtool with the same steps

zlib with the same steps

Openssl:
./Configure -lsocket -lbind --prefix=/boot/home/config 386 beos-elf
Then do make and make install

Openssh:
Type the next line in the terminal before running configure or make
export CFLAGS="-DUSE_PIPES -I/boot/develop/headers/bone -O2 "
./configure --prefix=/boot/home/config --with-ssl-dir=/boot/home/config
Then do make and then make install

postgresql:
./configure in the apache directory
back to the postgresql directory
./configure --prefix=/boot/apps/database/postgresql
then do make and then make install

PHP:
add the following lines to your .profile then restart your terminal if you have it open.
#export C_INCLUDE_PATH=/boot/develop/headers/be/bone/
#export CPLUS_INCLUDE_PATH=/boot/develop/headers/be/bone/
export C_INCLUDE_PATH="/boot/develop/headers/be/bone:/boot/develop/headers/be/bone/arpa:/boot/develop/headers/be/bone/isc:/boot/develop/headers/be/bone/libtelnet:/boot/develop/headers/be/bone/net:/boot/develop/headers/be/bone/netinet:/boot/develop/headers/be/bone/rpc:/boot/develop/headers/be/bone/sys"
export CPLUS_INCLUDE_PATH="/boot/develop/headers/be/bone:/boot/develop/headers/be/bone/arpa:/boot/develop/headers/be/bone/isc:/boot/develop/headers/be/bone/libtelnet:/boot/develop/headers/be/bone/net:/boot/develop/headers/be/bone/netinet:/boot/develop/headers/be/bone/rpc:/boot/develop/headers/be/bone/sys"

./configure --prefix=/boot/apps/www/php --with-apache=/boot/home/files/code/apache_1.3.20 --with-config-file-path=/boot/home/config/settings --with-openssl=/boot/home/config --without-mysql --with-pgsql=/boot/apps/database/postgresql --with-zlib-dir=/boot/home/config --with-gnu-ld
make
make install

Apache:
Link the files in /boot/apps/database/postgresql/lib to /boot/home/config/lib

./configure --prefix=/boot/apps/www/apache --activate-module=src/modules/php4/libphp4.a --disable-module=env --disable-module=userdir --disable-module=setenvif --disable-module=imap --disable-module=cgi --disable-module=actions --disable-module=autoindex --disable-module=status
make
make install

copy php.ini-dist /boot/home/config/settings/php.ini
You can customize the settings for PHP by editing this config file

Edit your httpd.conf or srm.conf file and add:
AddType application/x-httpd-php .php
Comment the User and Group lines
You can customize other settings as well.

To run your server all the time:
Add /boot/apps/www/apache/bin/apachectl start to UserBootScript
Add /boot/apps/www/apache/bin/apachectl stop to UserShutDownScript
* If for some reason Apache isn't shut down properly you may need to delete httpd.pid to get it to start again.  Don't just go killing Apache, shut it down nice like God intended.  :^)

Special Thanks to Pete at http://www.beforever.com for most of the info contained here.  Thanks to BGA, Jeremy, and the whole BeShare crew who I pester on a regular basis (Jeremy is the dancing paperclip for BeShare done yet?).  :^)

10/17/01